JBoss Community Archive (Read Only)

Teiid 8.3

Data Federation Example

The investor's portfolio example will demonstrate the ability of Teiid to integrate multiple datasources so that a single query can return results from 1 or more of those sources.   This data federation ability can make data integration of new sources easier without having to expose any new access details. 

dynamicvdb-datafederation quickstart
All the code discussed in this tutorial is available in the  dynamicvdb-datafederation  quickstart.

See the README.md for directions to run the quick start.

In this example, 2 datasources will be used;  Account Information, stored in a H2 database, and Market Data (Stock prices), stored in a CSV text file.  The VDB, which we will call DynamicPortfolio, will define a model for each data source; Account and MarketData, respectively.  The VDB will be deployed to the Teiid Runtime, thereby, making it accessible to the user application using JDBC.   To read about all the options for connecting to your VDB, see the Client Developer's Guide.

 images/author/download/attachments/63635707/portfoliodiagram.png
When the test query is executed that joins data from the Accounts and MarketData models, Teiid will access both, the relational and non-relational sources, calculate the portfolio values, and return the results.

JBoss.org Content Archive (Read Only), exported from JBoss Community Documentation Editor at 2020-03-13 12:38:03 UTC, last content change 2013-03-14 16:27:33 UTC.